-
Notifications
You must be signed in to change notification settings - Fork 13.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Mavlink check transmit buffer before send #10394
Conversation
dagar
commented
Sep 2, 2018
•
edited by AuterionWrikeBot
Loading
edited by AuterionWrikeBot
- partially addresses review PX4 Mavlink module write helper (send_bytes) #10389
@PX4/testflights this needs testing, but we should sort out your radio issues first. Scenarios to test and review (from logs).
Enable logging from boot so that the log contains the initial parameter and mission sync. Then do a short flight so we can see how the mavlink module responds (gracefully degrading or not). |
Looks good to me, we just need to make sure we're not missing side effects. @bkueng Could you please also have a look? |
We'll need to check the worst case mavlink packet size (largest + signing) that we'd like to support. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A few remarks:
- There are race conditions where it will fail. However I see no correctnes errors.
- signature header length is not included in
get_size()
A simple & clean solution would be to change MAVLINK_START_UART_SEND
to return a bool, and only call the _mavlink_send_uart
s if it returns true. (https://github.com/mavlink/c_library_v2/blob/master/mavlink_helpers.h#L349)
Actually I was thinking of doing that as well to catch the sends not coming from a stream update call. We'd need to find a way to introduce it as a non-breaking change to the upstream project (https://github.com/ArduPilot/pymavlink/blob/master/generator/C/include_v2.0/mavlink_helpers.h#L348-L355). On the PX4 side I'd still like to skip the work and save the data when possible.
Could you elaborate? I'm aware of the general disconnect between mavlink deciding it's time to send and the actual uorb data availability. Again, I'd strongly prefer to not throw away good data.
This needs to be fixed regardless. Are you aware of any actual mavlink signing usage? |
couple flights on a pixracer (v4) unable to establish proper connection; probably a hardware issue with SiK radio |
As discussed offline, @santiago3dr's telemetry radios seem to have a severe problem unrelated to this PR. We'll reconvene for testing once there's a stable baseline. |
got the new telemtry radios which are getting good range. ran the same range test on this pr and rtl kept getting rejected; disconnected telemtry radio and still not able to engage rtl @dagar thoughts? |
19b269c
to
4883996
Compare
@santiago3dr RTL failed because you didn't have a valid home position. I've rebased the PR on master, could you try again? |
@santiago3dr Could you re-test? Thanks! |
mixed results great connection; better connection than with master same test and environment on master cfac2cc for comparison: |
@santiago3dr your radio RSSI looks much better, but in all of your logs mavlink is still reporting flow control disabled. |
The hlybro radio's we got only have 4 wire connectors so no go on CTS and RTS |
Well that's unfortunate. We have some other ideas that will help, but nothing immediate. This is all kind of secondary to this PR though. @dogmaphobic FYI |
@santiago3dr could you try newer QGC daily? With only telemetry connected take a look at "Loss rate" under Settings -> Mavlink. |
@dagar What's your conclusion here? |
4883996
to
302a305
Compare
302a305
to
3b69692
Compare
This issue has been automatically marked as stale because it has not had recent activity. Thank you for your contributions. |
Closing as stale. |